#!/usr/bin/python
# -*- coding: utf-8 -*-
# 曹志强
# 知识
# 2023.09.11

from django.db import models


from common.base_model import NameLongModel
from system.models import SystemType


# Create your models here.

# 活动记录总结
class ActivityLearning(NameLongModel):
    changsuo = models.ForeignKey(SystemType,verbose_name="类型",related_name="activitychangsuo",limit_choices_to={ "typename" : "场所"},on_delete=models.CASCADE,null=True,blank=True)
    theme = models.ForeignKey(SystemType,verbose_name="主题",related_name="activitytheme",limit_choices_to={ "typename" : "活动主题"},on_delete=models.CASCADE,null=True,blank=True)
    #peoplejoin = models.ManyToManyField(Connections,verbose_name="参加人",limit_choices_to={"isrxxs":True,"invalid":False},null=True,blank=True)
    #content = UEditorField(verbose_name="内容",null=True,blank=True)
    content = models.CharField(verbose_name="内容", max_length=2000, blank=True, null=True)
    date = models.DateField(verbose_name="日期")
    remark = models.CharField(verbose_name="备注", max_length=20, blank=True, null=True)
    periods = models.IntegerField(verbose_name="期数",default=0,help_text='0代表临时活动')
    class Meta:
        verbose_name = '活动总结'
        verbose_name_plural = '活动总结'